# -*- coding: utf-8 -*

import os
import csv

from google.appengine.ext import webapp
from google.appengine.ext import db

import datastore

class UpdateLocationsPage(webapp.RequestHandler):
    def get(self):
        rows = datastore.HotSpot.all().fetch(1000)
        for row in rows:
            row.update_location()
            row.put()

        rows = datastore.Stop.all().fetch(1000)
        for row in rows:
            row.update_location()
            row.put()

        self.response.out.write('ok')
